<template>
	<view>
		<view class="active">
			<text>{{now_time}}日消息通知</text>
		</view>
		<view class="active2 active3">
			<view class="topnav">
				<image src="../static/yuanjiao.png" mode=""></image>
				<text>阅读人次{{all_view_nums}}次</text>
			</view>
			<view class="bottomnav" v-for="(item,index) in school" :key='index'>
			<!-- <view class="one">
				<image src="../static/xh.png" mode=""></image>
			</view> -->
			<view class="two">
				<text>{{item.school_name}}，阅读{{item.view_nums}}次</text>
			</view>
			<view class="three" >
				<view class="centerright" v-if="index==0">
					<text>最高</text>
				</view>
			</view>
			</view>
		</view>
		
	
	</view>
</template>

<script>
	export default {
		data() {
			return {
				company_id:0,
				school:[],
				now_time:'',
				all_view_nums:0
			}
		},
		methods: {
			jiaoyujvxq() {
				this.$store
					.dispatch('jiaoyujvxq', {
						company_id: this.company_id,
						type: "message"
					})
					.then(res => {
						console.log(res)
						this.school = res.data.data.school
						this.now_time = res.data.data.now_time
						this.all_view_nums = res.data.data.all_view_nums
			
					});
			}
			
		},
		onLoad(data) {
			this.company_id = data.company_id
			this.jiaoyujvxq()
		}
	}
</script>

<style lang="less">
page{
	background-color: #f4f4f4;
}
.active{
	width: 100%;
	height: 120rpx;
	background-color: #fff;
	font-size: 32rpx;
	font-weight: bold;
	color: #000;
	line-height: 120rpx;
	padding: 0 20rpx;
	margin-bottom: 20rpx;
}
.active2{
	width: 100%;
	height: 260rpx;
	background-color: #fff;
	margin-bottom: 20rpx;
	// padding: 0 20rpx;
	box-sizing: border-box;
	.topnav{
		width: 100%;
		height: 80rpx;
		border-bottom:2rpx solid #ccc;
		font-size: 30rpx;
		font-weight: bold;
		color: #0a98f7;
		line-height: 80rpx;
		padding: 0 20rpx;
		image{
			width: 9rpx;
			height: 26rpx;
			margin-right: 10rpx;
		}
	}
	.bottomnav{
		display: flex;
		flex-direction: column;
		justify-content: space-evenly;
		align-items: center;
		width: 100%;
		height: 180rpx;
		font-size: 28rpx;
		background-color: #fff;
		color: #000;
		.bottomwen{
			font-size: 26rpx;
			color: #ccc;
		}
	}
}
.active3{
	height: 230rpx;
	.bottomnav{
		display: flex;
		flex-direction: row;
		box-sizing: border-box;
		height: 150rpx;
		.one{
			display: flex;
			justify-content: center;
			align-items: center;
			width: 100rpx;
			height: 100%;
			// background-color: red;
				
			image{
				width: 100rpx;
				height: 100rpx;
				border-radius: 50%;
			}
		}
		.two{
			display: flex;
			align-items: center;
			height: 100%;
			width: calc(100% - 260rpx);
			// background-color: green;
			font-size: 30rpx;
			color: #4e4e4e;
			padding-left: 20rpx;
		}
		.three{
			width: 160rpx;
			height: 100%;
			// background-color: blue;
			display: flex;
			justify-content: center;
			align-items: center;
			.centerright{
				text-align: center;
				line-height: 50rpx;
				width: 120rpx;
				height: 50rpx;
				border-radius: 25rpx;
				background-color: #fda64a;
				font-size: 26rpx;
				color: #fff;
			}
		}
	}
		
	
}
</style>
